package com.four.basicinfo.service.impl;

import com.four.basicinfo.dao.MigrateDao;
import com.four.basicinfo.entity.Migrate;
import com.four.basicinfo.service.MigrateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class MigrateServiceImpl implements MigrateService {
    @Autowired
    MigrateDao migrateMapper;
    /**
     * 查询移居
     *
     * @param id 移居主键
     * @return 移居
     */
    @Override
    public Migrate selectMigrateById(Long id)
    {
        return migrateMapper.selectMigrateById(id);
    }
    /**
     * 新增移居
     *
     * @param migrate 移居
     * @return 结果
     */
    @Override
    public int insertMigrate(Migrate migrate)
    {
        return migrateMapper.insertMigrate(migrate);
    }

    /**
     * 修改移居
     *
     * @param migrate 移居
     * @return 结果
     */
    @Override
    public int updateMigrate(Migrate migrate)
    {
        return migrateMapper.updateMigrate(migrate);
    }
    /**
     * 删除移居信息
     *
     * @param id 移居主键
     * @return 结果
     */
    @Override
    public int deleteMigrateById(Long id)
    {
        return migrateMapper.deleteMigrateById(id);
    }
}
